/**
 * 重新发起录用
 */
import React from 'react';
import AuthComponent from '@/utils/auth/AuthComponent';
import { history } from 'umi'

import { Icon } from '../../components';

function HireRelaunchOperate({ candidateId, employId, ...rest }) {
    const handleJump = React.useCallback(() => {
        history.push({
            pathname: '/office/personnelManagement/recruitment/hire/communicate',
            query: { action: 'edit', candidateId, employId, type: 'hr' }
        });
    }, [candidateId, employId]);
    return (
        <AuthComponent code="office:recruitment:course:hire:relaunch">
            <Icon title="重新发起录用" type="zhongxinfaqiluyongshenpi" onClick={handleJump} {...rest} />
        </AuthComponent>
    );
}
export default HireRelaunchOperate;
